<extend name="Public/common" />
<block name="body">
<div class="wrapper wrapper-content animated fadeInRight">
    <div class="row">
        <div class="col-sm-12">
            <div class="ibox float-e-margins">
                <div class="ibox-title">
                    <h5>添加角色</h5>
                </div>
                <div class="ibox-content">
                    <div class="form-horizontal">
                        <div class="form-group">
                            <label class="col-sm-2 control-label">角色名称</label>

                            <div class="col-sm-10">
                                <input type="text" class="form-control" name="name" placeholder="请填写角色名称" id="name">
                            </div>
                        </div>
                        <div class="hr-line-dashed"></div>

                        <div class="form-group">
                            <label class="col-sm-2 control-label">权限分配</label>

                            <div class="col-sm-10">
                                <volist name="auth" id="auth">
                                    <div class="checkbox i-checks">
                                        <label>
                                            {$auth.level}<input type="checkbox" name="auth" value="{$auth.id}"> <i></i>{$auth.name}
                                        </label>
                                    </div>
                                </volist>
                            </div>
                        </div>
                        <div class="hr-line-dashed"></div>

                        <div class="form-group">
                            <label class="col-sm-2 control-label">
                                状态
                            </label>

                            <div class="col-sm-10">
                                <div class="radio i-checks">
                                    <label><input type="radio" value="0" name="status" checked="checked"> <i></i> 启用</label>
                                    <label><input type="radio" value="1" name="status"> <i></i>禁用</label>
                                </div>
                            </div>
                        </div>
                        <div class="hr-line-dashed"></div>

                        <div class="form-group">
                            <div class="col-sm-4 col-sm-offset-2">
                                <button class="btn btn-primary" id="save">保存内容</button>
                                <button class="btn btn-white" type="button" onclick="history.go(-1);">返回</button>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
<script>
    //定义全局变量
    var GV = {
        role_addrole : "{:U('Role/addRole')}"
    };
</script>
<script src="__JS__/http/role/addrole.js"></script>
</block>